import requests
# 登录的地址
url = 'https://so.gushiwen.cn/user/login.aspx?from=http%3a%2f%2fso.gushiwen.cn%2fuser%2fcollect.aspx'
# 用户名和密码
email = '793390457@qq.com'
pwd = "xlg17346570232"
# 表单数据
data = {
        "__VIEWSTATE": "1FClS0KnSNVXOhY/k04JfwQB/bmEmb09u9DuGPwln527V7RWbOfsk027f5NQuTFCY8MLC1ru7SkJ42sDWYxePaAzbrNUWfElMQ+8Qc32NkrtGEy6O2f6KXCGGgHdic1XUXkCfd8GHPlWhLajW3sykYCeCsU=",
        "__VIEWSTATEGENERATOR": "C93BE1AE",
        "from": "http://so.gushiwen.cn/user/collect.aspx",
        "email": email,
        "pwd": pwd,
        "code": "1231",
        "denglu": "登录"
}
# 请求头
headers = {
    'Content-Type':'application/x-www-form-urlencoded',
    'User-Agent':'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36',
    'Referer':'https://so.gushiwen.cn/user/login.aspx?from=http://so.gushiwen.cn/user/collect.aspx'
}
res = requests.post(url, headers=headers, data=data)
print(res.content.decode())